<?php use common\models\Article;?>

<?php $this->beginBlock('title'); ?><?=$model['title']?>_二狐游戏<?php $this->endBlock();?>
<?php $this->beginBlock('keywords'); ?><?=$game['info']['seo_keyword'];?><?php $this->endBlock();?>
<?php $this->beginBlock('description'); ?><?=$game['info']['seo_description'];?><?php $this->endBlock();?>

<?php if($game):?>
<div class="me_shadow public new_public">
    <div class="hot_game">
        <ul>
            <li>
            <a href="<?=Yii::$app->urlManager->createUrl(['game/detail','version_id'=>$game_version['id']]);?>">
                <p class="p1"><img src="<?=filepath($game['game_logo']);?>" class="myimg"></p>
                <p class="p2">
                <span class="span1"><?=$game['game_name'];?></span>
                <span class="span2"><?=$game_version['version_size'];?>MB <br><i>
                <?php foreach($game['types'] as $type):?>
                <?=$type['type_name'].' ';?>
                <?php endforeach;?>
                </i>下载：<em><?=$game['game_downclick'];?></em></span>
                </p>
                <p class="p3"><span>下载</span></p>
            </a>
            </li>
        </ul>
    </div>
</div>
<?php endif;?>
<div class="me_shadow public">
<div class="local"><?php if($game):?><a href="<?=Yii::$app->urlManager->createUrl(['game/detail','version_id'=>$game_version['id']]);?>"><?=$game['game_name'];?></a><?php endif;?>
<a href="<?=Yii::$app->urlManager->createUrl(['game/article-list','version_id'=>$game_version['id'],'kind'=>$model['kind']]);?>">手游<?=$model['kind']==Article::KIND_NEWS?'新闻':'活动'?></a> 正文</div>
<div class="detail_tit"><span><?=truncate($model['title'],24,'..');?></span><em><?=date('Y-m-d',$model['created_at']);?></em><em>作者: <?=$model['author'];?></em></div>
<div class="detail_font">
    <?=$model['content'];?>
</div>
<div class="detail_page">
    <?php if($prev):?><p>上一篇：<a href="<?=Yii::$app->urlManager->createUrl(['article/detail','id'=>$prev['id']]);?>"><?=$prev['title'];?></a></p><?php endif;?>
    <?php if($next):?><p>下一篇：<a href="<?=Yii::$app->urlManager->createUrl(['article/detail','id'=>$next['id']]);?>"><?=$next['title'];?></a></p><?php endif;?>
</div>
</div>

<!--相关文章 -->
<div class="me_shadow public">
    <div class="tit"><p class="p1">相关文章</p></div>
    <div class="game_news">
        <ul>
            <?php foreach($about as $item):?>
            <?php if($item['kind']==Article::KIND_NEWS):?>
            <li><span><a href="<?=Yii::$app->urlManager->createUrl('article/news-list');?>">[<?=$item['kind']==Article::KIND_NEWS?'新闻':'活动'?>]</a></span><p><a href="<?=Yii::$app->urlManager->createUrl(['article/detail','id'=>$item['id']]);?>"><?=$item['title'];?></a></p></li>
            <?php elseif($item['kind']==Article::KIND_ACTIVITY):?>
            <li><span><a href="<?=Yii::$app->urlManager->createUrl('article/activity-list');?>">[<?=$item['kind']==Article::KIND_NEWS?'新闻':'活动'?>]</a></span><p><a href="<?=Yii::$app->urlManager->createUrl(['article/detail','id'=>$item['id']]);?>"><?=$item['title'];?></a></p></li>
            <?php endif;?>
            <?php endforeach;?>
        </ul>
    </div>
</div>

<!--同类游戏 -->
<?php if($same_games):?>
<div class="me_shadow public">
     <div class="tit"><p class="p6">同类游戏</p></div>
     <div class="new_online">
     <ul class="clearfix">
        <?php foreach ($same_games as $game):?>
            <li><a href="<?=Yii::$app->urlManager->createUrl(['/game/detail','version_id'=>$game['id']]);?>"><img src="<?=filepath($game['game']['game_logo']);?>" class="myimg"><span><?=$game['game']['game_name'];?></span><em>下载</em></p></a></li>
        <?php endforeach;?>
        </ul>
     </div>
</div>
<?php endif;?>